<#import "/spring.ftl" as s/>
<@override name="project">
${project.name}
</@override>
<@override name="styles">
<link rel="stylesheet" type="text/css" href="<@s.url '/resources/styles/issue/list.css'/>"/>
</@override>
<@override name="main">
<div id="issue_tab" hidebody="true">
    <div id="todo" title="<@s.message "issue.tab.todo"/>">
    </div>
    <div id="done" title="<@s.message "issue.tab.done"/>">
    </div>
    <div id="all" title="<@s.message "issue.tab.all"/>">
    </div>
    <div id="my_issue" title="<@s.message "issue.tab.my_issue"/>">
    </div>
</div>

<div id="issue_toolbar" art="toolbar" borders="0">
</div>
<div id="issue_list">
</div>
<div id="label_change_div" title="<@s.message 'issue.label.lay.title' />">
    <input type="hidden" id="label_select_val" value=""><br/>
    <ul id="choose_label" class="color-label-list filter-list small">
        <#list labels as label>
                <li title="${label.description}" class="js_choose_label" id="lable_${label.id}" color="${label.color}" name="${label.name}"
                        value="${label.id}" onclick="issue_list.label_f_click('lable_${label.id}');">
                        <a href="javascript:;" id="lable_${label.id}_link" class="filter-item color-label" value="${label.id}">
                        <span class="color" style="background-color: ${label.color}"></span>&nbsp;
                        <span class="name">${label.name}</span>
                        </a>
                </li>
        </#list>
    </ul>
    <div class="rule"></div>
    <button id="choose_ok_label" onclick="issue_list.choose_ok();"><span><span><@s.message 'operation.confirm'/></span></span></button>
    <button id="choose_close_label" class="float_right" onclick="issue_list.choose_label_close();"><span><span><@s.message 'operation.cancel'/></span></span></button>
</div>
<div id="priopity_change_div_list"title="<@s.message 'issue.priopity.lay.title' />" style="">
        <input type="hidden" id="priopity_select_val" value=""><br/>
        <ul id="choose_priopity" class="color-label-list filter-list small">
                <#list priopities as priopity>
                <li title="${priopity.description}" class="js_choose_label" id="priopity_${priopity.id}" name="${priopity.name}"
                        value="${priopity.id}" onclick="issue_list.priopity_f_click('priopity_${priopity.id}');">

                        <a href="javascript:;" id="priopity_${priopity.id}_link" class="filter-item color-label" value="${priopity.id}">
                        &nbsp;<img src="/cdms/resources/common/images/${priopity.iconUrl}"/>
                        <span class="name">${priopity.name}</span>
                        </a>
                </li>
                </#list>
        </ul>
        <div class="rule"></div>
        <button id="choose_ok_priopity" onclick="issue_list.priopity_choose_ok();"><span><span><@s.message 'operation.confirm'/></span></span></button>
        <button id="choose_close_priopity" class="float_right" onclick="issue_list.priopity_choose_close();">
        <span><span><@s.message 'operation.cancel'/></span></span></button>
</div>

<#--<div id="issue_comment_back" style="display: none;">-->
<#--<div style="padding: 3px;margin: 3px;">-->
<#--<span id="issue_comment_summary"></span>-->
<#--<form id='form_answer' action="<@s.url '/issue/comment'/>" method="post">-->
<#--<input id="issue_comment_id" name="issue" value="" type="hidden">-->
<#--<textarea id='txt_answner' name='content' style='width:600px;height:260px;'></textarea>-->

<#--<br/>-->
<#--<span id='form_msg' style='display:none;'></span>-->
<#--<div style="float: right;" width="400px" height="60px" background="black">-->
<#--<div style="float: left;"><button id="btn_submit" type="button" onclick="issue_list.quick_comment_submit()">-->
<#--<span><span> <@s.message 'issue.button.comment'/> </span></span>-->
<#--</button>-->
<#--</div>-->
<#---->
<#--<div style="float: right;">-->
<#--<button id="btn_cancel" type="button" onclick="issue_list.close_layer('issue_comment_back')">-->
<#--<span><span> <@s.message 'operation.cancel'/> </span></span>-->
<#--</button>-->
<#--</div>-->
<#--</div>-->
<#--</form>-->
<#--</div>-->
<#--</div>-->

<div id="issue_close_comment_back" style="display: none;">
    <div style="padding: 3px;margin: 3px;">
        <form id='close_form_answer' action="<@s.url '/issue/close_comment'/>" method="post">
            <textarea id='close_txt_answner' name='content' style='width:500px;height:260px;'></textarea>
            <br/>
            <span id='close_form_msg' style='display:none;'></span>
            <div style="float: right;" width="400px" height="60px" background="black">
                <div style="float: left;"><button id="close_btn_submit" type="button" onclick="issue_list.close_comment_submit()">
                    <span><span> <@s.message 'issue.operation.close'/> </span></span>
                </button>
                </div>
                <div style="float: right;">
                    <button id="close_btn_cancel" type="button" onclick="issue_list.close_layer('issue_close_comment_back')">
                        <span><span> <@s.message 'operation.cancel'/> </span></span>
                    </button>
                </div>
            </div>
        </form>
    </div>
</div>
<div id="issue_fix_comment_back" style="display: none;">
    <div style="padding: 3px;margin: 3px;">
            <form id='fix_form_answer'  method="post">
                <input id="fix_issue_comment_id" name="issue_ids" value="" type="hidden">
                <textarea id='fix_txt_answner' name='content' style='width:500px;height:260px;'></textarea>

                <br/>
                <span id='fix_form_msg' style='display:none;'></span>
                <div style="float: right;" width="400px" height="60px" background="black">
                	<div style="float: left;"><button id="fix_btn_submit" type="button" onclick="issue_list.fix_comment_submit()">
                        <span><span> <@s.message 'issue.operation.fix'/> </span></span>
                  	</button>
                  	</div>

                  	<div style="float: right;">
                  	<button id="fix_btn_cancel" type="button" onclick="issue_list.close_layer('issue_fix_comment_back')">
                        <span><span> <@s.message 'operation.cancel'/> </span></span>
                  	</button>
                  	</div>
                </div>
            </form>
    </div>
</div>

<div id="single_assign" yfillee="true" art="layer" panel_body="true">
</div>
<div id="single_milestone" yfillee="true" art="layer" panel_body="true">
</div>


</@override>
<@override name="scripts">
<script type="text/javascript">
    var project_id = ${project.id};
    var milestone_id=${milestone_id};
    var type_list = ${type_json};
    var names = [];
    var priopity_list =${priopities_json};
    var js_param ={
        image_url :'<@s.url '/resources/common/images'/>',
        issue_list_json_url :'<@s.url '/project/issue/list.json'/>',
        upload_url: '<@s.url '/action/upload'/>',
        close_issue_url:'<@s.url '/issue/close'/>',
        open_issue_url:'<@s.url '/issue/reopen/'/>',
        view_assign_submit     : '<@s.url '/issue/view_assign_submit'/>',
        view_issue_accounts_url: '<@s.url '/issue/view_assign/'/>',
        label_change_url:'<@s.url '/issue/label_change/'/>',
        priopity_change_url:'<@s.url '/issue/priopity_change/'/>',

        issue_get_milestones_url: '<@s.url '/project/issue/get_project_milestones/'/>',
        issue_set_milestones_url: '<@s.url '/project/issue/set_milestones'/>',

        close_comment_submit_url : '<@s.url '/issue/close_comment_submit'/>',
        fix_comment_submit_url  : '<@s.url '/issue/fix_comment_submit'/>'

    };

    <#--view_issue_accounts_url: '<@s.url '/issue/view_assign/'/>',-->
    <#--issue_set_milestones_url: '<@s.url '/issue/set_milestones/'/>',-->



</script>
<script type="text/javascript" src="<@s.url '/resources/common/ke/kindeditor-min.js'/>" charset="utf-8"></script>
<script type="text/javascript" src="<@s.url '/resources/scripts/project/issue/list.js'/>"></script>
</@override>
<@extends name="/common/projectlayout1.1.ftl" current="issue" title="" code="${project.code}"></@extends>